<jsp:directive.page contentType="text/html;charset=utf-8" />
<%@ include file="/taglibs.jsp" %>

<head>
<%@ include file="/WEB-INF/jsps/includes/jqueryui.jsp"%>
<%@ include file="/WEB-INF/jsps/includes/jqgrid.jsp"%>
	<style>
		body { font-size: 62.5%; }
		/*label, input { display:block; }*/
		input.text { margin-bottom:12px; width:95%; padding: .4em; }
		fieldset { padding:0; border:0; margin-top:25px; }
		h1 { font-size: 1.2em; margin: .6em 0; }
		div#users-contain { width: 350px; margin: 20px 0; }
		div#users-contain table { margin: 1em 0; border-collapse: collapse; width: 100%; }
		div#users-contain table td, div#users-contain table th { border: 1px solid #eee; padding: .6em 10px; text-align: left; }
		.ui-dialog .ui-state-error { padding: .3em; }
		.validateTips { border: 1px solid transparent; padding: 0.3em; }
	</style>
<script type="text/javascript">
$(document).ready(function(){
	var lastsel; 
	jQuery("#list").jqGrid( {
		url : 'catalog!catalogJsonList.action',
		datatype : "json",
		prmNames : {
			page : "jq.requestPage", rows : "jq.pageSize", sort : "jq.sortColumn",
			order : "jq.sortDirection", search : "jq._search", nd : "jq.nd", npage : null},
		jsonReader : {
			root : "rows", repeatitems : false, id : "0"},
		colNames : [ '<s:text name="module.common.id"/>',
					 '<s:text name="module.catalog.catalogCode"/>', 
		 			 '<s:text name="module.catalog.catalogName"/>', 
		 			 '<s:text name="module.catalog.parentCatalogName"/>',
		 			 '<s:text name="module.common.description"/>'],
		colModel : [ {name : 'id',index : 'id', width : 20, hidden:true}, 
					 {name : 'catalogCode',index : 'catalogCode', width : 120},
		     		 {name : 'catalogName',index : 'catalogName',width : 120},
		     		 {name : 'parentCatalog.catalogName',sortable : false,width : 150},
		     		 {name : 'description',sortable : false, width : 250}],		
		rowNum : 15,
		rowList : [15,30,50],
		height: 'auto',
		pager : '#pager',
		sortname : 'catalogCode',
		viewrecords: true,
		sortorder : 'asc',
		loadOnce : true,
		caption : "Catalogs List"
	});
});
</script>
</head>


<body>
<div id="popupDialogSelectBox" title="Create new user">
<table id="list"></table>
<div id="pager"></div>
</div>



<script type="text/javascript">

</script>


</body>
